import {ThemeConfig} from 'antd';
import {createSlice, PayloadAction} from '@reduxjs/toolkit';

const theme: ThemeConfig = {
    token: {
    },
    components: {
        Layout: {
            headerBg: '#fff',
            siderBg: '#fff'
        }
    }
};
const themeSlice = createSlice({
    name: 'image',
    initialState: theme,
    reducers: {
        setValue(state, actions: PayloadAction<Partial<typeof theme>>) {
            Object.assign(state, actions.payload);
        }
    }
});

export const {setValue} = themeSlice.actions;
export default themeSlice.reducer;
